import re
six=re.compile('[1-9]{1}\d{5}')
year=re.compile('(19|20)\d{2}')
month=re.compile('(0[1-9]|1[0-2])(0[1-9]|[1-2]\d|3[0-1])')
last_4=re.compile('(\d{3}x|\d{4})')
id_card=re.compile('[1-9]{1}\d{5}(19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2]\d|3[0-1])(\d{3}x|\d{4})')
_id='430381200104296055'
result=id_card.search(_id).group()
if result:
    print(result)
else:
    print('error')